<template>
    <div class="box">
        <ul class="shop">
            <li v-for="item in arr" :key="item">
                <router-link to="/rxb">{{item.name}}</router-link>
            </li>
            
        </ul>
        
        <RouterView></RouterView>
    </div>
    

</template>

<script>
import axios from 'axios';
export default {
    data(){
        return {
            arr: []
        }
    },
    methods: {
        async xiao() {
            const aaa= await axios.get("http://localhost:3006");
            console.log(aaa);
            this.arr=aaa.data.data[0].goods;

            console.log(this.arr);
        }
    },
    created(){
        this.xiao();
        // console.log(arr);
    },
}
</script>

<style>
*{
padding: 0;
margin: 0;
}
.box {
    display: flex;
    /* height: 100%; */
}
::-webkit-scrollbar{
    width: 0 !important;
}
.shop {
    display: flex;
    flex-direction: column;
    background-color: #f3f5f7;
/* 左边占25% */
    width: 25%;
    /* height: 60%; */
    /* height: 113vw;
    overflow: scroll; */
    /* overflow-y: hidden; */
    
}

.shop li {
    text-align: center;
    padding: 3.667vw 0vw ;
    font-size: 4.2vw;
    border-bottom: 1px solid rgb(7, 17, 27, 0.1);
}


.right {
    background-color: chocolate;
}

</style>